<!DOCTYPE html>
<html lang="en">
<head>
	<meta charset="UTF-8">
	<meta name="viewport" content="width = device-width,user-scalable = no">
	<title>Document</title>
	<script src="MTween.js"></script>
	<style>
	* {
		margin: 0;
		padding: 0;
	}
	#box {
		width: 100px;
		height: 100px;
		padding: 100px;
		border: 1px solid #ccc;
	}
	#div {
		height: 100px;
		background:red;
/*		-webkit-transform:rotate(60deg);
		transform: rotate(60deg);*/
	}
	</style>
</head>
<body>
	<div id="box">
		<div id="div"></div>
	</div>

	<script>
		var div = document.querySelector('#div');
		fn1();
		function fn1(){
			MTween({
				el : div,
				target: {
					scale : 0,
					rotate : 720
				},
				time : 2000,
				type : 'easeOut',
				callBack : fn2
			});
		}
		function fn2(){
			MTween({
				el : div,
				target: {
					scale : 100,
					rotate : 0
				},
				time : 2000,
				type : 'easeOut',
				callBack : fn1
			});
		}
	</script>
</body>
</html>